<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>EDIFIER</title>
		<link rel="stylesheet" type="text/css" href="css/register.css"/>
		<script src="js/jquery-3.6.0.min.js" type="text/javascript" charset="utf-8"></script>
		<meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0,user-scalable=no"id="viewport"/>
	</head>
	<body>
		<!-- 整体布局 -->
		<div class="container">
			<!-- 登录框 -->
			<div class="containerform containerform-signup">
				<form action="/" method="get" class="form" id="form1">
					<h2>欢迎登录</h2>
					<p><label>用户名:<input type="text" name="user" id="user" placeholder="请输入用户名" value=""/></label></p>
					<p><label>密&nbsp;&nbsp;&nbsp;码:<input type="password" name="pwd" id="pwd"placeholder="请输入密码"/></label></p>
					<p style="margin-top: 10%;"><a href="#">忘记密码？</a></p>
					<button type="button" id="login" style="margin-top: 10%;">登录</button>
					<button type="button" class="btn">没有账号，点击注册</button>
				</form>
				<form action="/" method="get" class="form" id="form2">
					<h2>注册账号</h2>
					<p><label>用户名:<input type="text" name="user" id="user1" placeholder="请输入用户名"/></label></p>
					<p><label>密&nbsp;&nbsp;&nbsp;码:<input type="password" name="pwd" id="pwd1"placeholder="请输入密码"/></label></p>
					<button type="button" id="register" style="margin-top: 10%;">点击注册</button>
					<button type="button" class="btn">已有账号，直接登录</button>
				</form>
			</div>
		</div>
	</body>
	<script src="js/register.js" type="text/javascript" charset="utf-8"></script>
	<script type="text/javascript">
		document.getElementById("login").onclick=function(){
			var user=document.getElementById("user").value;
			var pwd=document.getElementById("user").value;
			if(user.value==="黎华爽"&&pwd.value===123){
				console.log(1)
				window.location.href="index.html"
			}
		}
	</script>
</html>
